﻿using System;
using System.Linq.Expressions;
using ilgolosone.DomainModel.Entities;
using ilgolosone.Shared.Domain;

namespace ilgolosone.DomainModel.Queries
{
    public class FindReservationByDate : IDomainQuery<Reservation>
    {
        private readonly DateTime _reservationDate;

        public FindReservationByDate(DateTime reservatioDate)
        {
            _reservationDate = reservatioDate;
        }

        public Expression<Func<Reservation, bool>> Criteria
        {
            get { return restaurant => restaurant.ReservationDate == _reservationDate; }
        }
    }
}
